package com.chen.service.Impl;

import com.chen.mapper.OrderMapper;
import com.chen.pojo.bean.WsResult;
import com.chen.service.OrderServcie;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

@Service("orderServcie")
public class OrderServcieImpl implements OrderServcie {

    @Autowired
    private OrderMapper orderMapper;


    @Override
    public int updateOrder(WsResult.ResultObj resultObj) {
        return orderMapper.updateState(resultObj.getTradeNo(), Integer.parseInt(resultObj.getStatus()), resultObj.getGmtPayment());
    }
}
